﻿using System.Collections.Generic;
using System.Data;
using Wei8808Cms.DAL;
using Wei8808Cms.Model;

namespace Wei8808Cms.BLL
{
    public class CaseBLL
    {
        private readonly CaseDAL _dal = new CaseDAL();

        public int GetCount()
        {
            return _dal.GetCount();
        }

        public DataSet GetPageList(Pagination qcmodel)
        {
            return _dal.GetPageList(qcmodel);
        }

        public bool Add(CaseInfo model)
        {
            return _dal.Add(model);
        }

        public bool Delete(List<CaseInfo> list)
        {
            return _dal.Delete(list);
        }

        public CaseInfo GetCaseInfo(int id)
        {
            return _dal.GetCaseInfo(id);
        }

        public bool Update(CaseInfo model)
        {
            return _dal.Update(model);
        }

        public bool UpdateField(int id, string strField)
        {
            return _dal.UpdateField(id, strField);
        }

        public List<CaseInfo> GetCaseList(int pageIndex, int pageSize)
        {
            return _dal.GetCaseList(pageIndex, pageSize);
        }

        public int GetTotal(string id)
        {
            return _dal.GetTotal(id);
        }
    }
}
